package com.atguigu.gulimall.auth.feign;

import com.atguigu.common.utils.R;
import com.atguigu.gulimall.auth.vo.SocialUser;
import com.atguigu.gulimall.auth.vo.UserLoginVo;
import com.atguigu.gulimall.auth.vo.UserRegisterVo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * @ ClassName MemberFeignService
 * @ Description TODO
 * @ Author admin
 * @ Date 2021/3/24 10:46
 * @ Version 1.0
 */
@FeignClient("gulimall-member")
public interface MemberFeignService {

    @PostMapping(value = "/member/member/register")
     R register(@RequestBody UserRegisterVo vo);

    @PostMapping(value = "/member/member/login")
    public R login(@RequestBody UserLoginVo vo);

    @RequestMapping("/member/member/oauth2/login")
    public R oauthLogin(@RequestBody SocialUser socialUser);
}
